﻿using System;
using System.Windows;
using System.Windows.Controls;


namespace Coding4Fun.Cannon.TechEdPhone.Complete.Controls
{
	public partial class NavigationControl : UserControl
	{
		public event EventHandler<ButtonNavigationEventArgs> ButtonNavigationChanged;

		public NavigationControl()
		{
			InitializeComponent();
		}



        private void OnButtonNavigationChanged(ButtonNavigation button)
        {
            if (ButtonNavigationChanged != null)
            {
                ButtonNavigationChanged(this, new ButtonNavigationEventArgs { NewButton = button });
            }
        }

        private void btnModeDrive_Checked(object sender, RoutedEventArgs e)
        {
            OnButtonNavigationChanged(ButtonNavigation.Drive);
        }

        private void btnModeAim_Checked(object sender, RoutedEventArgs e)
        {
            OnButtonNavigationChanged(ButtonNavigation.Aim);
        }

        private void btnModeFire_Checked(object sender, RoutedEventArgs e)
        {
            OnButtonNavigationChanged(ButtonNavigation.Fire);
        }



	}
}
